Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Backblaze Uninstaller and switch to latest version as Backblaze downloads are unversioned #88039

Closed
wants to merge 2 commits into from

Conversation

mudge
Copy link
Contributor

@mudge mudge commented Aug 23, 2020

Backblaze do not offer versioned downloads of their installer so attempting to upgrade the Cask causes issues with mismatched checksums if the previous installer is still cached.

This means we lose the ability to detect updates but forcibly upgrading the Cask (e.g. with brew cask upgrade backblaze) should now work as expected.

Rather than having to manually delete the various applications, preference panes and launchctl jobs installed by the Backblaze Installer ourselves, use the included Backblaze Uninstaller script instead.

Note that the Uninstaller will not delete user-specific files so we retain the existing zap stanza.

Important: Do not tick a checkbox if you haven’t performed its action. Honesty is indispensable for a smooth review process.

After making all changes to a cask, verify:

Backblaze do not offer versioned downloads of their installer so
attempting to upgrade the Cask causes issues with mismatched checksums
if the previous installer is still cached.

This means we lose the ability to detect updates but forcibly upgrading
the Cask (e.g. with `brew cask upgrade backblaze`) should now work as
expected.
@mudge mudge changed the title Use Backblaze Uninstaller and switch to latest version as Backblaze downloads are unversioned Use Backblaze Uninstaller and switch to latest version as Backblaze downloads are unversioned Aug 23, 2020
@mudge mudge force-pushed the unversioned-backblaze-downloads branch from 2a35d75 to ff8a887 Compare August 23, 2020 14:52
Casks/backblaze.rb Outdated Show resolved Hide resolved
Rather than having to manually delete the various applications,
preference panes and `launchctl` jobs installed by the Backblaze
Installer ourselves, use the included Backblaze Uninstaller script
instead.

Note that the Uninstaller will not delete user-specific files so we
retain the existing zap stanza.
@mudge mudge force-pushed the unversioned-backblaze-downloads branch from ff8a887 to 8f1c0fd Compare August 24, 2020 06:30
"#{appdir}/Backblaze.app",
"/Library/PreferencePanes/BackblazeBackup.prefPane",
]
uninstall script: "#{staged_path}/Backblaze Uninstaller.app/Contents/MacOS/Backblaze Uninstaller"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not a script, it will call a GUI which complicates automation and which we do not want until we can do it properly.


url "https://secure.backblaze.com/mac/install_backblaze.dmg"
appcast "https://secure.backblaze.com/api/clientversion.xml",
Copy link
Member

@vitorgalvao vitorgalvao Aug 24, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The whole point of the appcast is that we can detect when updates are available. It’s never* correct to delete a functioning appcast.

* It can happen, but it’s so rare it happened maybe once in almost a decade.

@@ -1,23 +1,14 @@
cask "backblaze" do
version "7.0.2.464"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It’s by having a version that brew upgrade can work properly. You’re removing that ability.

@vitorgalvao
Copy link
Member

The cask is correct as is. Everything you mentioned is done intentionally.

@mudge
Copy link
Contributor Author

mudge commented Aug 24, 2020

Thanks for reviewing, @vitorgalvao.

It's especially useful to know support for GUI uninstalls are a separate issue.

Re the versioning of Backblaze: in retrospect, sacrificing the functioning appcast and version is overkill when my original issue is a much smaller one: that upgrading Backblaze in-place fails because the checksum fails due to all versions of the installer being cached as install_backblaze.dmg.

Frustratingly, this is hard to reproduce due to the fact it's not possible to download an older version of the installer and I notice that all downloads in ~/Library/Caches/Homebrew/downloads seem to be prefixed with a checksum.

I'll re-test when a new version of the Backblaze installer is released to see if I can reproduce the problem more thoroughly then.

@mudge mudge deleted the unversioned-backblaze-downloads branch August 25, 2020 09:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants